package ooday02.eg;
/*动物家族测试类*/
public class AnimalTest {
    public static void main(String[] args) {

        //Dog:
        Dog dg = new Dog("小黑",3,"黑");
        dg.eat();//走的子类（）
        dg.drink();
        dg.LookHome();
        System.out.println();


        //Chick:
        Chick ch = new Chick("小羽",4,"黄");
        ch.eat();
        ch.drink();
        ch.layEggs();
        System.out.println();

        //Fish：
        Fish fi = new Fish("小金鱼",3,"金");
        fi.eat();
        fi.drink();
    }
}
